package com.googlecode.rjm.model;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

@Entity
@Table(name = "issue_categories")
public class Category extends Persistent {

	private static final long serialVersionUID = 3379632495340674701L;

	@Id
	private Integer id;

	@ManyToOne
	@JoinColumn(name = "project_id")
	private Project project;

	private String name;

	@ManyToOne
	@JoinColumn(name = "assigned_to_id")
	private User assignedTo;

	@Override
	public Integer getId() {
		return this.id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public Project getProject() {
		return this.project;
	}

	public void setProject(Project project) {
		this.project = project;
	}

	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public User getAssignedTo() {
		return this.assignedTo;
	}

	public void setAssignedTo(User assignedTo) {
		this.assignedTo = assignedTo;
	}
}
